package cn.u313.repository;

import cn.u313.entry.JiLuEntry;
import cn.u313.entry.PresentChildrenEntry;
import org.springframework.data.jpa.repository.JpaRepository;
import org.springframework.data.jpa.repository.JpaSpecificationExecutor;
import org.springframework.data.jpa.repository.Query;

public interface PresentChildrenRepository extends JpaRepository<PresentChildrenEntry, Integer>, JpaSpecificationExecutor<PresentChildrenEntry> {
    @Query(nativeQuery = true,value = "SELECT * FROM `t_yjilu` where id = '89152' ")
    JiLuEntry byQQ(String s);
    @Query(nativeQuery = true,value = "select count(1) from t_yjilu where to_days(time) = to_days(now()) and qq0 = :qq and type=:type ")
    int countByqqAndType(String qq,String type);
    @Query(nativeQuery = true,value = "select count(1) from t_yjilu where to_days(time) = to_days(now()) and qq0 = :qq and qq1 =:qq1")
    int countQqToQq1(String qq,String qq1);
//    public

}